/**
 * Copyright (c) 2013-Now http://jeesite.com All rights reserved.
 * No deletion without permission, or be held responsible to law.
 * @author YDZ
 */
import { defHttp } from '/@/utils/http/axios';
import { useGlobSetting } from '/@/hooks/setting';
import { BasicModel, Page } from '../model/baseModel';

const { adminPath } = useGlobSetting();

export interface M8Rd32 extends BasicModel<M8Rd32> {
  code?: string; // 出库单号
  cusCode?: string; // 客户编码
  ddate?: string; // 单据日期
  djStatus?: string; // 单据状态
  createByName?: string; // 制单人名称
  updateByName?: string; // 修改人名称
  m8Rds32List?: any[]; // 子表列表
}

export const m8Rd32List = (params?: M8Rd32 | any) =>
  defHttp.get<M8Rd32>({ url: adminPath + '/rd/rd32/m8Rd32/list', params });

export const m8Rd32ListData = (params?: M8Rd32 | any) =>
  defHttp.post<Page<M8Rd32>>({ url: adminPath + '/rd/rd32/m8Rd32/listData', params });

export const m8Rds32ListData = (params?: M8Rd32 | any) =>
  defHttp.post<Page<M8Rd32>>({ url: adminPath + '/rd/rd32/m8Rd32/m8Rds32ListData', params });

export const m8Rd32Form = (params?: M8Rd32 | any) =>
  defHttp.get<M8Rd32>({ url: adminPath + '/rd/rd32/m8Rd32/form', params });

export const m8Rd32Save = (params?: any, data?: M8Rd32 | any) =>
  defHttp.postJson<M8Rd32>({ url: adminPath + '/rd/rd32/m8Rd32/save', params, data });

export const m8Rd32Delete = (params?: M8Rd32 | any) =>
  defHttp.get<M8Rd32>({ url: adminPath + '/rd/rd32/m8Rd32/delete', params });

export const m8Rd32ScanPicAddRow = (params?: M8Rd32 | any) =>
  defHttp.post<M8Rd32>({ url: adminPath + '/rd/rd32/m8Rd32/scanPicAddRow', params });
